
export default class RankItem extends fgui.GButton {

    private _nameText: fgui.GTextField;
    private _goleText: fgui.GTextField;
    private _rankController: fgui.Controller;
    private _iconController: fgui.Controller;

    public constructor() {
        super();
    }

    protected onConstruct(): void {
        this._nameText = this.getChild("n6").asTextField;
        this._rankController = this.getController("n4");
        this._iconController = this.getController("n5");
        this._goleText = this.getChild("n7").asTextField;
    }

    public setName(value: string): void {
        this._nameText.text = value;
    }

    public setGoale(value: string): void {
        this._goleText.text = value;
    }

    // public setRead(value: boolean): void {
    //     this._readController.selectedIndex = value ? 1 : 0;
    // }

    // public setFetched(value: boolean): void {
    //     this._fetchController.selectedIndex = value ? 1 : 0;
    // }

    // public playEffect(delay: number): void {
    //     this.visible = false;
    //     this._trans.play(null, 1, delay);
    // }
}
